SRCS	:= bt829.c generic.c i2c.c mach64.c memory.c queue.c rage128.c board.c

ifneq ($(KERNELRELEASE),)

obj-m := genericv4l.o
genericv4l-objs := $(SRCS:%.c=%.o)

else
KDIR	:= /lib/modules/$(shell uname -r)/build
PWD	:= $(shell pwd)
MODULE  := genericv4l.ko
OBJS	:= $(patsubst %.c,%.o,$(SRCS))

default:
	$(MAKE) -C $(KDIR) SUBDIRS=$(PWD) modules
	sync

clean:
	rm -f $(MODULE) $(OBJS) genericv4l.mod.* .*o.cmd

endif
